home *** CD-ROM | disk | FTP | other *** search
- package com.sun.java.swing.plaf.metal;
-
- import com.sun.java.swing.Icon;
- import java.awt.Component;
- import java.awt.Graphics;
- import java.io.Serializable;
-
- public class MetalIconFactory$FileIcon16 implements Icon, Serializable {
- public void paintIcon(Component c, Graphics g, int x, int y) {
- g.translate(x, y + this.getShift());
- int right = MetalIconFactory.access$fileIcon16Size().width - 1;
- int bottom = MetalIconFactory.access$fileIcon16Size().height - 1;
- g.setColor(MetalLookAndFeel.getWindowBackground());
- g.fillRect(4, 2, 9, 12);
- g.setColor(MetalLookAndFeel.getPrimaryControlInfo());
- g.drawLine(2, 0, 2, bottom);
- g.drawLine(2, 0, right - 4, 0);
- g.drawLine(2, bottom, right - 1, bottom);
- g.drawLine(right - 1, 6, right - 1, bottom);
- g.drawLine(right - 6, 2, right - 2, 6);
- g.drawLine(right - 5, 1, right - 4, 1);
- g.drawLine(right - 3, 2, right - 3, 3);
- g.drawLine(right - 2, 4, right - 2, 5);
- g.setColor(MetalLookAndFeel.getPrimaryControl());
- g.drawLine(3, 1, 3, bottom - 1);
- g.drawLine(3, 1, right - 6, 1);
- g.drawLine(right - 2, 7, right - 2, bottom - 1);
- g.drawLine(right - 5, 2, right - 3, 4);
- g.drawLine(3, bottom - 1, right - 2, bottom - 1);
- g.translate(-x, -(y + this.getShift()));
- }
-
- public int getShift() {
- return 0;
- }
-
- public int getAdditionalHeight() {
- return 0;
- }
-
- public int getIconWidth() {
- return MetalIconFactory.access$fileIcon16Size().width;
- }
-
- public int getIconHeight() {
- return MetalIconFactory.access$fileIcon16Size().height + this.getAdditionalHeight();
- }
- }
-